package com.tjl.vending_machine.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import java.util.Date;
import com.baomidou.mybatisplus.annotation.TableId;
import java.io.Serializable;
import com.baomidou.mybatisplus.annotation.*;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import com.fasterxml.jackson.annotation.JsonInclude;
import lombok.Data;

/**
 * @auther CodeGenerator
 * @create 2021-02-20 15:46:35
 * @describe 实体类
 */
@Data
@TableName("product")
@JsonInclude(JsonInclude.Include.NON_NULL)
@ApiModel(value="Product对象", description="")
public class Product implements Serializable {

private static final long serialVersionUID = 1L;

            @TableId(value = "id", type = IdType.UUID)
                private String id;

    @ApiModelProperty(value = "商品关联的机器")
    @TableField("machine_id")
        private String machineId;

    @ApiModelProperty(value = "商品标题")
    @TableField("title")
        private String title;

    @ApiModelProperty(value = "商品详情描述")
    @TableField("description")
        private String description;

    @ApiModelProperty(value = "商品价格，单位分")
    @TableField("price")
        private Integer price;

    @ApiModelProperty(value = "商品图片")
    @TableField("img_id")
        private String imgId;

    @ApiModelProperty(value = "商品库存：默认1")
    @TableField("stock")
        private Integer stock;

    @ApiModelProperty(value = "商品位置编号,1,2,3,4,5,6")
    @TableField("product_index")
        private Integer productIndex;

    @ApiModelProperty(value = "状态:1正常，0下架")
    @TableField("status")
        private Integer status;

    @ApiModelProperty(value = "创建时间")
    @TableField("create_time")
        private Date createTime;

    @ApiModelProperty(value = "更新时间")
    @TableField("update_time")
        private Date updateTime;


    }